-- GENERATED SPELL FOR [Voidhunter Yar] --


function spell0_18683(pUnit, Event) --@Arcane Bolt,n/a--
pUnit:FullCastSpellOnTarget(38204,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18683', 1000, 1)
end

function spell1_18683(pUnit, Event) --@Damage Reduction: Arcane,Self--
pUnit:FullCastSpellOnTarget(34331,pUnit)
pUnit:RegisterEvent('Sorts_18683', 581, 1)
end

function spell2_18683(pUnit, Event) --@Damage Reduction: Fire,Self--
pUnit:FullCastSpellOnTarget(34333,pUnit)
pUnit:RegisterEvent('Sorts_18683', 634, 1)
end

function spell3_18683(pUnit, Event) --@Damage Reduction: Frost,Self--
pUnit:FullCastSpellOnTarget(34334,pUnit)
pUnit:RegisterEvent('Sorts_18683', 627, 1)
end

function spell4_18683(pUnit, Event) --@Damage Reduction: Holy,Self--
pUnit:FullCastSpellOnTarget(34336,pUnit)
pUnit:RegisterEvent('Sorts_18683', 578, 1)
end

function spell5_18683(pUnit, Event) --@Damage Reduction: Nature,Self--
pUnit:FullCastSpellOnTarget(34335,pUnit)
pUnit:RegisterEvent('Sorts_18683', 606, 1)
end

function spell6_18683(pUnit, Event) --@Damage Reduction: Shadow,Self--
pUnit:FullCastSpellOnTarget(34338,pUnit)
pUnit:RegisterEvent('Sorts_18683', 633, 1)
end

function spell7_18683(pUnit, Event) --@Fel Shackles,n/a--
pUnit:FullCastSpellOnTarget(38051,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18683', 7500, 1)
end

function spell8_18683(pUnit, Event) --@Fireball,n/a--
pUnit:FullCastSpellOnTarget(14034,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18683', 3000, 1)
end

function spell9_18683(pUnit, Event) --@Frostbolt,n/a--
pUnit:FullCastSpellOnTarget(15497,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18683', 7000, 1)
end

function spell10_18683(pUnit, Event) --@Holy Smite,n/a--
pUnit:FullCastSpellOnTarget(15498,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18683', 2500, 1)
end

function spell11_18683(pUnit, Event) --@Lightning Bolt,n/a--
pUnit:FullCastSpellOnTarget(12167,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18683', 3000, 1)
end

function spell12_18683(pUnit, Event) --@Shadow Bolt,n/a--
pUnit:FullCastSpellOnTarget(12471,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18683', 3000, 1)
end

function Sorts_18683(pUnit, Event)
local choix_sorts_18683 = math.random(0, 12)
if choix_sorts_18683 == 0 then
pUnit:RegisterEvent('spell0_18683', 1, 1)
end
if choix_sorts_18683 == 1 then
pUnit:RegisterEvent('spell1_18683', 1, 1)
end
if choix_sorts_18683 == 2 then
pUnit:RegisterEvent('spell2_18683', 1, 1)
end
if choix_sorts_18683 == 3 then
pUnit:RegisterEvent('spell3_18683', 1, 1)
end
if choix_sorts_18683 == 4 then
pUnit:RegisterEvent('spell4_18683', 1, 1)
end
if choix_sorts_18683 == 5 then
pUnit:RegisterEvent('spell5_18683', 1, 1)
end
if choix_sorts_18683 == 6 then
pUnit:RegisterEvent('spell6_18683', 1, 1)
end
if choix_sorts_18683 == 7 then
pUnit:RegisterEvent('spell7_18683', 1, 1)
end
if choix_sorts_18683 == 8 then
pUnit:RegisterEvent('spell8_18683', 1, 1)
end
if choix_sorts_18683 == 9 then
pUnit:RegisterEvent('spell9_18683', 1, 1)
end
if choix_sorts_18683 == 10 then
pUnit:RegisterEvent('spell10_18683', 1, 1)
end
if choix_sorts_18683 == 11 then
pUnit:RegisterEvent('spell11_18683', 1, 1)
end
if choix_sorts_18683 == 12 then
pUnit:RegisterEvent('spell12_18683', 1, 1)
end
end

function mob18683_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_18683', math.random(1500, 3000), 1)
end

function mob18683_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob18683_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob18683_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(18683, 1, 'mob18683_Action')
RegisterUnitEvent(18683, 2, 'mob18683_Leave')
RegisterUnitEvent(18683, 3, 'mob18683_Kill')
RegisterUnitEvent(18683, 4, 'mob18683_Die')
